using System;
using FluentNHibernate.Automapping;
using FluentNHibernate.Automapping.Alterations;
using MvcMall.Core.Domains;
using MvcMall.Core.Enums;

namespace MvcMall.Data.NHibernateMaps
{
    public class MailTemplateMap : IAutoMappingOverride<MailTemplate>
    {
        public void Override(AutoMapping<MailTemplate> mapping)
        {
            mapping.Map(c => c.MailTemplateType).CustomType(typeof(MailTemplateType)).Unique().Equals(true);
        }
    }
}